/*
 * @Author: 89-83-77
 * @Description: main.js配置文件
 * @Date: 2025-03-27 16:52:35
 * @LastEditTime: 2025-03-27 23:27:57
 * @FilePath: \event-analysis-systemd:\Desktop\client\src\main.js
 */
import { createApp } from "vue";
import App from "./App.vue";
import router from "./router";
import { createPinia } from "pinia";
import ElementPlus from "element-plus";
import "element-plus/dist/index.css";
import * as ElementPlusIconsVue from "@element-plus/icons-vue"; //引入element-plus-ui图标
import "@/assets/css/public.css"; //引入公共样式
import "@/assets/css/global.css"; //引入公共样式
import autoResize from "./utils/autoResize.js"; //自适应

const app = createApp(App); // 创建Vue实例

// 注册Element Plus图标
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component);
}
const pinia = createPinia(); // 创建Pinia实例
app.directive("auto-resize", autoResize);
app.use(pinia); // 注册Pinia
app.use(router); //注册路由
app.use(ElementPlus); //全局使用element-plus-ui组件库
app.mount("#app");
